<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
        
        <!-- 班级成绩录入 -->

<script type="text/javascript">
$(function(){
	$('#kc').selectmenu();
	$('#bj').selectmenu();
	$('#button').button();
})
	function cx(){
		var bjId=$('#bj').val();
		var kcId=$('#kc').val();
		if(kcId==0||bjId==0){
			$('#table').empty();
		}else{
			$('#table').load('classGrade/table',{bjId:bjId,kcId:kcId});
		}
	}
	
	function cjChange(id,value){
		$.post('classGrade/cjChange',{id:id,grade:value},function(data){});
	}
	
	function selectChange(){
		$('table').empty();
	}
</script>

<div>
	<div id="dialog3" style="display: none;"></div>
	<p align="center">
		<label>班级：</label>
		<select id="bj"  name="bj" onchange="selectChange()">
			<option value="0">---请选择---</option>
			<c:forEach items="${tbClass}" var="bj">
				<option value="${bj.id}">${bj.name}</option>
			</c:forEach>
		</select>
		<label>课程：</label>
		<select id="kc"  name="kc" onchange="selectChange()">
			<option value="0">---请选择---</option>
			<c:forEach items="${course}" var="kc">
				<option value="${kc.id}">${kc.name}</option>
			</c:forEach>
		</select>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
		<button onclick="cx()" id="button">查询</button>
	</p>
	<div id="table"></div>
</div>